package com.devunion.salon.core.model.security;

import com.devunion.salon.core.model.BaseSalonEntity;

import javax.persistence.ManyToMany;
import javax.persistence.Entity;
import java.util.List;

/**
 * @author spetrakovsky
 */
@Entity
public class Role extends BaseSalonEntity {

    private String name;

    @ManyToMany
    private List<Privilege> privileges;

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public List<Privilege> getPrivileges() {
        return privileges;
    }

    public void setPrivileges(List<Privilege> privileges) {
        this.privileges = privileges;
    }
}
